
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">

  
<!-- Mirrored from npp-community.tuxfamily.org/documentation/notepad-user-manual/commands by HTTrack Website Copier/3.x [XR&CO'2010], Wed, 30 Mar 2011 22:11:54 GMT -->
<!-- Added by HTTrack --><meta http-equiv="content-type" content="text/html;charset=utf-8"><!-- /Added by HTTrack -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Commands | </title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="prev" href="macros.html" />
<link rel="up" href="../notepad-online-document.html" />
<link rel="next" href="shortcuts-run-menu.html" />
<link rel="shortcut icon" href="../../sites/default/files/acquia_marina_favicon.gif" type="image/x-icon" />
<meta name="keywords" content="Notepad++ Documentation,Notepad++,text editor" />
<meta name="description" content="<br />
" />
    <link type="text/css" rel="stylesheet" media="all" href="../../modules/book/book5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../modules/node/node5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../modules/system/defaults5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../modules/system/system5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../modules/system/system-menus5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../modules/user/user5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/cck/theme/content-module5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/ckeditor/ckeditor5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/dhtml_menu/dhtml_menu5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/fancy_login/css/fancy_login5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/feedback/feedback5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/cck/modules/fieldgroup/fieldgroup5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/modules/views/css/views5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/style5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/icons5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/dblog5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/theme_settings/fixed5dbc.css?S" />
<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/theme_settings/fonts_15dbc.css?S" />
    <!--[if IE 7]>
      <link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/acquia_marina/ie7-fixes.css" />
    <![endif]-->
    <!--[if lte IE 6]>
      <link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/acquia_marina/ie6-fixes.css" />
    <![endif]-->
        <link type="text/css" rel="stylesheet" media="all" href="../../sites/all/themes/acquia_marina/local.css" />
    	<link type="text/css" rel="stylesheet" media="all" href="../../sites/all/css/home.css" />
    <script type="text/javascript" src="../../misc/jquery5dbc.js?S"></script>
<script type="text/javascript" src="../../misc/drupal5dbc.js?S"></script>
<script type="text/javascript" src="../../sites/all/modules/dhtml_menu/dhtml_menu5dbc.js?S"></script>
<script type="text/javascript" src="../../sites/all/modules/fancy_login/scripts/fancy_login5dbc.js?S"></script>
<script type="text/javascript" src="../../sites/all/modules/feedback/feedback5dbc.js?S"></script>
<script type="text/javascript" src="../../sites/all/themes/acquia_marina/script5dbc.js?S"></script>
<script type="text/javascript">
<!--//--><![CDATA[//><!--
jQuery.extend(Drupal.settings, { "basePath": "/", "dhtmlMenu": { "siblings": "siblings", "slide": 0, "relativity": 0, "children": 0, "clone": 0, "doubleclick": 0 }, "fancyLogin": { "screenFadeColor": "white", "screenFadeZIndex": "10", "loginBoxHeight": "auto", "loginBoxWidth": "175px", "loginBoxBackgroundColor": "white", "loginBoxTextColor": "black", "loginBoxBorderColor": "black", "loginBoxBorderWidth": "3px", "loginBoxBorderStyle": "solid", "loginPath": "user/login", "dimFadeSpeed": 500, "boxFadeSpeed": 1000, "hideObjects": 0, "requestDestination": "?destination=node/14" } });
//--><!]]>
</script>
  </head>

  <body class="not-logged-in not-front full-node node-type-book layout-first-main">
    <div id="page" class="clearfix">
      
              <div id="skip">
          <a href="#main-content">Skip to Main Content</a>
        </div>
            <div id="header-wrapper">
        <div id="header" class="clearfix">
          
                
          <div id="header-first">
             
            <div id="logo"><a href="../../index.html" title="Home"><img src="../../sites/all/images/NppCommunityLogo.png" alt="Home" /></a></div>
                                              </div><!-- /header-first -->
  
          <div id="header-middle">
                      </div><!-- /header-middle -->
      
          <div id="header-last">
                      </div><!-- /header-last -->
      
        </div><!-- /header -->
      </div><!-- /header-wrapper -->
      
      <div id="primary-menu-wrapper" class="clearfix">
                <div id="primary-menu">
          <ul class="menu"><li class="leaf first dhtml-menu "><a href="../notepad-online-document.html" title="Notepad++ User Manual" id="dhtml_menu-502">Documentation</a></li>
<li class="leaf last dhtml-menu "><a href="../../faq.html" title="" id="dhtml_menu-1031">FAQ</a></li>
</ul>        </div><!-- /primary_menu -->
              </div><!-- /primary-menu-wrapper -->

      <div id="preface">
              </div><!-- /preface -->

      <div id="main-wrapper">
        <div id="main" class="clearfix">
          
                  
                    <div id="sidebar-first">
            
<!-- start block.tpl.php -->
<div class="block-wrapper odd">
     <!-- see preprocess_block() -->
  <div class="rounded-block">
    <div class="rounded-block-top-left"></div>
    <div class="rounded-block-top-right"></div>
    <div class="rounded-outside">
      <div class="rounded-inside">
        <p class="rounded-topspace"></p>
        
        <div id="block-book-0" class="block block-book">
                                <div class="block-icon pngfix"></div>
                      <h2 class="title block-title pngfix">Documentation Navigation</h2>
                    <div class="content">
            <ul class="menu"><li class="collapsed first no-dhtml "><a href="file-management.html" id="dhtml_menu-504">File management</a></li>
<li class="collapsed  no-dhtml "><a href="session-management.html" id="dhtml_menu-505">Session management</a></li>
<li class="collapsed  no-dhtml "><a href="editing.html" id="dhtml_menu-508">Editing</a></li>
<li class="collapsed  no-dhtml "><a href="document-properties.html" id="dhtml_menu-509">Document Properties</a></li>
<li class="collapsed  no-dhtml "><a href="searching.html" id="dhtml_menu-511">Searching</a></li>
<li class="collapsed  no-dhtml "><a href="display.html" id="dhtml_menu-510">Display</a></li>
<li class="leaf  no-dhtml "><a href="macros.html" id="dhtml_menu-512">Macros</a></li>
<li class="leaf  no-dhtml  active-trail"><a href="commands.html" id="dhtml_menu-513" class="active">Commands</a></li>
<li class="leaf  no-dhtml "><a href="shortcuts-run-menu.html" id="dhtml_menu-514">Shortcuts for the Run menu</a></li>
<li class="leaf  no-dhtml "><a href="windows-dialog.html" id="dhtml_menu-515">Windows Dialog</a></li>
<li class="collapsed  no-dhtml "><a href="gui-elements.html" id="dhtml_menu-744">GUI elements</a></li>
<li class="collapsed  no-dhtml "><a href="switching-between-documents.html" id="dhtml_menu-745">Switching between Documents</a></li>
<li class="collapsed  no-dhtml "><a href="languages.html" id="dhtml_menu-746">Languages</a></li>
<li class="collapsed  no-dhtml "><a href="settings.html" id="dhtml_menu-747">Settings</a></li>
<li class="leaf  no-dhtml "><a href="plugins.html" id="dhtml_menu-749">Plugins</a></li>
<li class="leaf  no-dhtml "><a href="command-line.html" id="dhtml_menu-750">Command Line</a></li>
<li class="leaf  no-dhtml "><a href="control-files.html" id="dhtml_menu-751">Control files</a></li>
<li class="leaf  no-dhtml "><a href="shell-extension.html" id="dhtml_menu-752">Shell Extension</a></li>
<li class="collapsed  no-dhtml "><a href="further-help.html" id="dhtml_menu-748">Further help</a></li>
<li class="leaf  no-dhtml "><a href="upgrading.html" id="dhtml_menu-753">Upgrading</a></li>
<li class="leaf last no-dhtml "><a href="credits.html" id="dhtml_menu-754">Credits</a></li>
</ul>          </div>
        </div>
  
          <p class="rounded-bottomspace"></p>
      </div><!-- /rounded-inside -->
    </div>
    <div class="rounded-block-bottom-left"></div>
    <div class="rounded-block-bottom-right"></div>
  </div><!-- /rounded-block -->
    
</div>
<!-- /end block.tpl.php -->
          </div><!-- /sidebar-first -->
          
          <div id="content-wrapper">

            
                        
            <div id="content">
              <a name="main-content" id="main-content"></a>
              
              
              <div id="content-inner">
                
                              
                                <h1 class="title">Commands</h1>
                                <div id="content-content">
                  
<!-- start node.tpl.php -->
<div id="node-14" class="node odd full-node node-type-book">
  
  
  <div class="meta">
      </div>

  <div class="content">
    <p>
	Commands allow you to execute applications from Notepad++, for example to open your current file in a browser or compile it with some external compiler. You can pass the program command line parameters based on the current status of your document.</p>
<p>
	<img alt="" src="../../Images/Screenshots/run.png" style="width: 300px; height: 185px;" /></p>
<p>
	&nbsp;</p>
<h3>
	To run a new command:</h3>
<p>
	Sselect <span class="menu_item">Run-&gt;Run...</span>. A dialog will pop up asking for the path to the program and possible any command line parameters. You can use the browse button to search for your program. The drop down list provides recently run programs. The command line arguments can also be based on the status of the current document, and are always enclosed in $(...), where &hellip; can be:</p>
<dl>
<dt>
		FULL_CURRENT_PATH</dt>
<dd>
		the fully qualified path to the current document.</dd>
<dt>
		CURRENT_DIRECTORY</dt>
<dd>
		The directory the current document resides in.</dd>
<dt>
		FILE_NAME</dt>
<dd>
		The filename of the document, without the directory.</dd>
<dt>
		NAME_PART</dt>
<dd>
		The filename without the extension.</dd>
<dt>
		EXT_PART</dt>
<dd>
		The extension of the current document.</dd>
<dt>
		NPP_DIRECTORY</dt>
<dd>
		The directory that contains the notepad++.exe executable that is currently running.</dd>
<dt>
		&gt;CURRENT_WORD</dt>
<dd>
		The currently selected text in the document.</dd>
<dt>
		CURRENT_LINE</dt>
<dd>
		The current line number that is selected in the document (0 based index, the first line is 0).</dd>
<dt>
		CURRENT_COLUMN</dt>
<dd>
		The current column the cursor resides in (0 based index, the first position on the line is 0).</dd>
</dl>
<p>
	For example,</p>
<table border="1" bordercolor="#000000" cellpadding="4" cellspacing="0" width="100%">
<colgroup>
		<col width="256*" /><br />
	</colgroup>
<tbody style="font-family: monospace;">
<tr>
<td valign="top" width="100%">
				<strong><font size="2"><span style="background-color:Aquamarine;">&quot;$(NPP_DIRECTORY)\notepad++.exe&quot; -multiInst &quot;$(FULL_CURRENT_PATH)&quot;</span></font></strong></td>
</tr>
</tbody>
</table>
<p>
	would start a new instance of Notepad++ opening the current file. Remember to put quotes around paths if it can contain spaces. For the Notepad++ command line options, see Command Line.</p>
<p>
	&nbsp;</p>
<h3>
	To run an existing command:</h3>
<p>
	Select it from the Run menu below the <span class="menu_item">Run...</span> option. If no commands are saved, the list will be empty.</p>
<p>
	<img alt="" src="../../Images/Screenshots/save_shortcut.png" style="width: 276px; height: 188px;" /></p>
<p>
	&nbsp;</p>
<p>
	&nbsp;</p>
<h3>
	To save the command:</h3>
<p>
	Sselect <span class="menu_item">Run-&gt;Run...</span>, enter the command and press <span class="button">Save...</span>. A dialog will pop up asking for a name of the command and the default key combination. Once saved, the command will be available from the Run menu.</p>
<p>
	&nbsp;</p>
<h3>
	To edit or delete an existing command:</h3>
<p>
	The Shortcut Mapper (see&nbsp;<a href="settings/shortcut-mapper.html">Shortcut Mapper</a>) displays all available commands in a uniform way, so you can modify or delete any shortcut you defined, including <span class="menu_item">Run</span> commands. This procedure is also available from <span class="menu_item">Run -&gt; Modify shortcut / Delete command</span>. As the name suggests, this does not extend to editing the command text proper - you need to edit <tt>shortcuts.xml</tt> to do that.</p>
  <div id="book-navigation-3" class="book-navigation">
    
        <div class="page-links clear-block">
              <a href="macros.html" class="page-previous" title="Go to previous page">‹ Macros</a>
                    <a href="../notepad-online-document.html" class="page-up" title="Go to parent page">up</a>
                    <a href="shortcuts-run-menu.html" class="page-next" title="Go to next page">Shortcuts for the Run menu ›</a>
          </div>
    
  </div>
  </div>

    
  
  </div>
<!-- /#node-14 -->
                </div>
              </div><!-- /content-inner -->
            </div><!-- /content -->

                      </div><!-- /content-wrapper -->
          
          
                    
          
                    <div id="footer" class="clearfix">
                        
<!-- start block.tpl.php -->
<div class="block-wrapper odd">
        
        <div id="block-fancy_login-0" class="block block-fancy_login">
                    <div class="content">
            <a href="../../user/login.html">Login</a>          </div>
        </div>
  
    
</div>
<!-- /end block.tpl.php -->
                                    
<!-- start block.tpl.php -->
<div class="block-wrapper odd">
        
        <div id="block-system-0" class="block block-system">
                    <div class="content">
            <a href="http://drupal.org/"><img src="../../misc/powered-blue-80x15.png" alt="Powered by Drupal, an open source content management system" title="Powered by Drupal, an open source content management system" width="80" height="15" /></a>          </div>
        </div>
  
    
</div>
<!-- /end block.tpl.php -->
                                  </div><!-- /footer -->
                    
        </div><!-- /main -->
      </div><!-- /main-wrapper -->
    </div><!-- /page -->
    <div id="fancy_login_dim_screen"></div><div id="fancy_login_login_box"><div id="fancy_login_form_contents"><a href="#" id="fancy_login_close_button">X</a><form id="user-login" method="post" accept-charset="UTF-8" action="http://npp-community.tuxfamily.org/user/login"><div><div class="form-item" id="edit-name-wrapper">
 <label for="edit-name">Username: <span class="form-required" title="This field is required.">*</span></label>
 <input type="text" maxlength="60" name="name" id="edit-name" size="15" value="" tabindex="1" class="form-text required" />
</div>
<div class="form-item" id="edit-pass-wrapper">
 <label for="edit-pass">Password: <span class="form-required" title="This field is required.">*</span></label>
 <input type="password" name="pass" id="edit-pass"  maxlength="128"  size="15"  tabindex="2" class="form-text required" />
</div>
<input type="hidden" name="form_id" id="edit-user-login" value="user_login"  />
<input type="hidden" name="form_build_id" id="form-e075724b080dd5579cefcfd6f7f3f68f" value="form-e075724b080dd5579cefcfd6f7f3f68f"  />
<input type="submit" name="op" id="edit-submit" value="Log in"  tabindex="3" class="form-submit" />
</div></form><div class="item-list"><ul><li class="first"><a href="../../user/register.html" title="Create a new user account.">Create new account</a></li>
<li class="last"><a href="../../user/password.html" title="Request new password via e-mail.">Request new password</a></li>
</ul></div></div><div id="fancy_login_ajax_loader"><img src="../../sites/all/modules/fancy_login/images/ajax-loader.gif" alt="Loading" /></div></div>

<!-- start block.tpl.php -->
<div class="block-wrapper even">
        
        <div id="block-feedback-form" class="block block-feedback">
                                <h2 class="title block-title pngfix"><span class="feedback-link">Feedback</span></h2>
                    <div class="content">
            <form action="http://npp-community.tuxfamily.org/documentation/notepad-user-manual/commands"  accept-charset="UTF-8" method="post" id="feedback-form" class="feedback-form">
<div><input type="hidden" name="ajax" id="edit-ajax" value="0"  />
<div class="feedback-help">If you experience a bug or would like to see an addition on the current page, feel free to leave us a message.</div><div class="form-item" id="edit-message-wrapper">
 <label for="edit-message">Message: <span class="form-required" title="This field is required.">*</span></label>
 <textarea cols="60" rows="5" name="message" id="edit-message"  class="form-textarea resizable required feedback-message"></textarea>
</div>
<div id="feedback-throbber"><input type="submit" name="op" id="feedback-submit" value="Send"  class="form-submit" />
</div><input type="hidden" name="form_build_id" id="form-86786e3fedab1280ed7ba57d5b055ba5" value="form-86786e3fedab1280ed7ba57d5b055ba5"  />
<input type="hidden" name="form_id" id="edit-feedback-form" value="feedback_form"  />

</div></form>
          </div>
        </div>
  
    
</div>
<!-- /end block.tpl.php -->
  </body>

<!-- Mirrored from npp-community.tuxfamily.org/documentation/notepad-user-manual/commands by HTTrack Website Copier/3.x [XR&CO'2010], Wed, 30 Mar 2011 22:11:55 GMT -->
<!-- Added by HTTrack --><meta http-equiv="content-type" content="text/html;charset=utf-8"><!-- /Added by HTTrack -->
</html>
